<template>
<view>
	<view class="avatar">
	    <image :src="avatar"></image>
	</view>
	<button @click="jump('/pages/login/personal')" class="strue">个人用户注册</button>
	<button @click="jump('/pages/login/company')" class="sfalse">机构用户注册</button>
</view>
</template>

<script>
import request from '@/util/request.js'
export default {
	data() {
		return {
			avatar:uni.getStorageSync('avatarUrl')
		}
	},
	onShow(e){
		if(uni.getStorageSync('role') !== 1){
			uni.switchTab({
				url:'/pages/index/index'
			})
		}
	},
	methods: {
		jump(url){
			uni.navigateTo({
				url:url
			});
		}
	}
}
</script>

<style>
	@import url("./index.css");
</style>
